package org.jeecg.modules.xindian.reconciliation.mapper;

import java.util.List;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.xindian.reconciliation.controller.req.ReportManagerReq;
import org.jeecg.modules.xindian.reconciliation.controller.rsp.BrokerageFeeSettlementInfoExcel;
import org.jeecg.modules.xindian.reconciliation.controller.rsp.ChannelBrokerageFeeSettlementInfo;
import org.jeecg.modules.xindian.reconciliation.controller.rsp.ChannelSettlementPolicyInfoExcel;
import org.jeecg.modules.xindian.reconciliation.controller.rsp.SettlementPolicyInfoExcel;
import org.jeecg.modules.xindian.reconciliation.dto.rsp.ChannelReportInfo;
import org.jeecg.modules.xindian.reconciliation.dto.rsp.InComeReportInfo;
import org.jeecg.modules.xindian.reconciliation.dto.rsp.SalesmanManagerInfo;
import org.jeecg.modules.xindian.reconciliation.dto.rsp.SalesmanReportInfo;
import org.jeecg.modules.xindian.reconciliation.entity.ChannelSettlementInfo;
import org.jeecg.modules.xindian.reconciliation.entity.PolicySettlementStatistics;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

/**
 * @Description: policy_settlement_statistics
 * @Author: jeecg-boot
 * @Date:   2024-05-06
 * @Version: V1.0
 */
public interface PolicySettlementStatisticsMapper extends BaseMapper<PolicySettlementStatistics> {
    void cleanChannelSettlementInfo(@Param("settlementId") String settlementId);
    void cleanSalesmanSettlementInfo(@Param("settlementId") String settlementId);
    void cleanInsuranceSettlementInfo(@Param("settlementId") String settlementId);

    List<ChannelSettlementPolicyInfoExcel> queryChannelPolicyInfo(@Param("settlementId")String settlementId);
    List<ChannelSettlementPolicyInfoExcel> queryChannelUnSettlementPolicyInfo(@Param("settlementId")String settlementId);
    List<SettlementPolicyInfoExcel> querySalemanPolicyInfo(@Param("settlementId")String settlementId);
    List<SettlementPolicyInfoExcel> queryInsurancePolicyInfo(@Param("settlementId")String settlementId);
    List<BrokerageFeeSettlementInfoExcel> querySalesmanFeeBySettlementId(@Param("settlementId")String settlementId);
    List<BrokerageFeeSettlementInfoExcel> queryChannelFeeBySettlementId(@Param("settlementId")String settlementId);
    List<BrokerageFeeSettlementInfoExcel> queryInsuranceFreeBySettlementId(@Param("settlementId")String settlementId);


    List<ChannelReportInfo> queryChannelReportInfo(@Param("date")String date,@Param("company")String company);
    List<SalesmanReportInfo> querySalemanReportInfo(@Param("date")String date,@Param("company")String company);
    List<SalesmanReportInfo> queryNaturalTrafficReport(@Param("date")String date,@Param("company")String company);
    List<InComeReportInfo> queryInsuranceReportInfo(@Param("date")String date,@Param("company")String company);


    IPage<SalesmanManagerInfo> queryChannelInfo(Page page, @Param("date")String date,@Param("payDate")String payDate);
    IPage<SalesmanManagerInfo> querySalemanInfo(Page page, @Param("date")String date,@Param("payDate")String payDate);
    IPage<SalesmanManagerInfo> queryInsuranceInfo(Page page,@Param("date")String date,@Param("payDate")String payDate);

    /**
     * 渠道经纪费结算单
     * @param id
     * @return
     */
    List<ChannelBrokerageFeeSettlementInfo> listByIdChannelBrokerageFeeSettlementInfos(@Param("id") String  id);


    List<SettlementPolicyInfoExcel> querySettlementPolicyInfo(ReportManagerReq req);




}

